import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [{
        path: '/home',
        name: 'Home',
        component: () =>
            import ('../views/home.vue')
    },
    {
        path: '/fun',
        name: 'Fun',
        component: () =>
            import ('../views/fun.vue')
    },
    {
        path: '/bei',
        name: 'Bei',
        component: () =>
            import ('../views/bei.vue')
    },
    {
        path: '/cityList',
        name: 'CityList',
        component: () =>
            import ('../views/cityList.vue')
    },
    {
        path: '/newList',
        name: 'NewList',
        component: () =>
            import ('../views/newList.vue')
    },
    {
        path: '/algin',
        name: 'Algin',
        component: () =>
            import ('../views/algin.vue')
    },
    {
        path: '/register',
        name: 'Register',
        component: () =>
            import ('../views/register.vue')
    },
    {
        path: '/self',
        name: 'Self',
        component: () =>
            import ('../views/self.vue')
    },
    {
        path: '/talk',
        name: 'Talk',
        component: () =>
            import ('../views/talk.vue')
    },
    {
        path: '/sou',
        name: 'Sou',
        component: () =>
            import ('../views/sou.vue')
    },
    { path: "/", redirect: "/home" }
]

const router = new VueRouter({
    base: process.env.BASE_URL,
    routes
})

export default router